package com.nsl.my_youlai.common.enums;

import com.baomidou.mybatisplus.annotation.EnumValue;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonValue;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.nsl.my_youlai.common.base.IBaseEnum;
import com.nsl.my_youlai.jackson.DocxTemplateStatusEnumDeserializer;
import com.nsl.my_youlai.mystar.enums.EnumTypeEnum;
import com.nsl.my_youlai.mystar.enums.NslEnumBaseI;
import lombok.Getter;

/**
 * 状态枚举
 *
 * @author haoxr
 * @since 2022/10/14
 */
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
@JsonDeserialize(using = DocxTemplateStatusEnumDeserializer.class)
public enum DocxTemplateStatusEnum implements NslEnumBaseI<Integer> {

    EDIT(1, "编辑"),
    PUBLISH (0, "启用");


    @EnumValue
    private Integer value;


    private String label;

    DocxTemplateStatusEnum(Integer value, String label) {
        this.value = value;
        this.label = label;
    }

//    @JsonValue
    @Override
    public Integer getValue() {
        return this.value;
    }

    @Override
    public String getLabel() {
        return this.label;
    }

    @Override
    public EnumTypeEnum getEnumType() {
        return null;
    }


}
